<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.14"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>xadcps: Main Page</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<link href="HTML_custom.css" rel="stylesheet" type="text/css"/>
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><img alt="Logo" src="xlogo_bg.gif"/></td>
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">xadcps
   </div>
   <div id="projectbrief">Xilinx SDK Drivers API Documentation</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.14 -->
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
$(function() {
  initMenu('',false,false,'search.php','Search');
});
</script>
<div id="main-nav"></div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
$(document).ready(function(){initNavTree('index.html','');});
</script>
<div id="doc-content">
<div class="header">
  <div class="headertitle">
<div class="title">xadcps Documentation</div>  </div>
</div><!--header-->
<div class="contents">
<div class="textblock"><p>The <a class="el" href="struct_x_adc_ps.html" title="The driver&#39;s instance data. ">XAdcPs</a> driver supports the Xilinx XADC/ADC device.The XADC/ADC device has the following features:</p><ul>
<li>10-bit, 200-KSPS (kilo samples per second) Analog-to-Digital Converter (ADC)</li>
<li>Monitoring of on-chip supply voltages and temperature</li>
<li>1 dedicated differential analog-input pair and 16 auxiliary differential analog-input pairs</li>
<li>Automatic alarms based on user defined limits for the on-chip supply voltages and temperature</li>
<li>Automatic Channel Sequencer, programmable averaging, programmable acquisition time for the external inputs, unipolar or differential input selection for the external inputs</li>
<li>Inbuilt Calibration</li>
<li>Optional interrupt request generation</li>
</ul>
<p>The user should refer to the hardware device specification for detailed information about the device.</p>
<p>This header file contains the prototypes of driver functions that can be used to access the XADC/ADC device.</p>
<p><b> XADC Channel Sequencer Modes </b></p>
<p>The XADC Channel Sequencer supports the following operating modes:</p>
<ul>
<li><b> Default </b>: This is the default mode after power up. In this mode of operation the XADC operates in a sequence mode, monitoring the on chip sensors: Temperature, VCCINT, and VCCAUX.</li>
<li><b> One pass through sequence </b>: In this mode the XADC converts the channels enabled in the Sequencer Channel Enable registers for a single pass and then stops.</li>
<li><b> Continuous cycling of sequence </b>: In this mode the XADC converts the channels enabled in the Sequencer Channel Enable registers continuously.</li>
<li><b> Single channel mode</b>: In this mode the XADC Channel Sequencer is disabled and the XADC operates in a Single Channel Mode. The XADC can operate either in a Continuous or Event driven sampling mode in the single channel mode.</li>
<li><b> Simultaneous Sampling Mode</b>: In this mode the XADC Channel Sequencer will automatically sequence through eight fixed pairs of auxiliary analog input channels for simulataneous conversion.</li>
<li><b> Independent ADC mode</b>: In this mode the first ADC (A) is used to is used to implement a fixed monitoring mode similar to the default mode but the alarm fucntions ar eenabled. The second ADC (B) is available to be used with external analog input channels only.</li>
</ul>
<p>Read the XADC spec for more information about the sequencer modes.</p>
<p><b> Initialization and Configuration </b></p>
<p>The device driver enables higher layer software (e.g., an application) to communicate to the XADC/ADC device.</p>
<p><a class="el" href="group__xadcps__v2__2.html#ga57807452402a6b52dd48083f676bd4ff" title="This function initializes a specific XAdcPs device/instance. ">XAdcPs_CfgInitialize()</a> API is used to initialize the XADC/ADC device. The user needs to first call the <a class="el" href="group__xadcps__v2__2.html#gadf27053ce16b799289b609bce586aa21" title="Functions in xadcps_sinit.c. ">XAdcPs_LookupConfig()</a> API which returns the Configuration structure pointer which is passed as a parameter to the <a class="el" href="group__xadcps__v2__2.html#ga57807452402a6b52dd48083f676bd4ff" title="This function initializes a specific XAdcPs device/instance. ">XAdcPs_CfgInitialize()</a> API.</p>
<p><b>Interrupts</b></p>
<p>The XADC/ADC device supports interrupt driven mode and the default operation mode is polling mode.</p>
<p>The interrupt mode is available only if hardware is configured to support interrupts.</p>
<p>This driver does not provide a Interrupt Service Routine (ISR) for the device. It is the responsibility of the application to provide one if needed. Refer to the interrupt example provided with this driver for details on using the device in interrupt mode.</p>
<p><b> Virtual Memory </b></p>
<p>This driver supports Virtual Memory. The RTOS is responsible for calculating the correct device base address in Virtual Memory space.</p>
<p><b> Threads </b></p>
<p>This driver is not thread safe. Any needs for threads or thread mutual exclusion must be satisfied by the layer above this driver.</p>
<p><b> Asserts </b></p>
<p>Asserts are used within all Xilinx drivers to enforce constraints on argument values. Asserts can be turned off on a system-wide basis by defining, at compile time, the NDEBUG identifier. By default, asserts are turned on and it is recommended that users leave asserts on during development.</p>
<p><b> Building the driver </b></p>
<p>The <a class="el" href="struct_x_adc_ps.html" title="The driver&#39;s instance data. ">XAdcPs</a> driver is composed of several source files. This allows the user to build and link only those parts of the driver that are necessary.</p>
<p><b> Limitations of the driver </b></p>
<p>XADC/ADC device can be accessed through the JTAG port and the PLB interface. The driver implementation does not support the simultaneous access of the device by both these interfaces. The user has to care of this situation in the user application code.</p>
<p><br />
<br />
</p>
<pre></pre><pre>MODIFICATION HISTORY:</pre><pre>Ver   Who    Date     Changes
<hr/>

1.00a ssb    12/22/11 First release based on the XPS/AXI xadc driver
1.01a bss    02/18/13   Modified XAdcPs_SetSeqChEnables,XAdcPs_SetSeqAvgEnables
                XAdcPs_SetSeqInputMode and XAdcPs_SetSeqAcqTime APIs
                in <a class="el" href="xadcps_8c.html">xadcps.c</a> to fix CR #693371
1.03a bss    11/01/13 Modified <a class="el" href="xadcps__hw_8h.html">xadcps_hw.h</a> to use correct Register offsets
                CR#749687
2.1   bss    08/05/14 Added declarations for XAdcPs_SetSequencerEvent,
                XAdcPs_GetSamplingMode, XAdcPs_SetMuxMode,
                XAdcPs_SetPowerdownMode and XAdcPs_GetPowerdownMode
                functions.
                Modified Assert for XAdcPs_SetSingleChParams in
                <a class="el" href="xadcps_8c.html">xadcps.c</a> to fix CR #807563.
2.2   bss    04/27/14 Modified to use correct Device Config base address in
                                        <a class="el" href="xadcps_8c.html">xadcps.c</a> (CR#854437).
      ms     01/23/17 Added xil_printf statement in main function for all
                      examples to ensure that "Successfully ran" and "Failed"
                      strings are available in all examples. This is a fix
                      for CR-965028.
      ms     03/17/17 Added readme.txt file in examples folder for doxygen
                      generation.</pre><pre></pre> </div></div><!-- contents -->
</div><!-- doc-content -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="footer">Copyright &copy; 2015 Xilinx Inc. All rights reserved.</li>
  </ul>
</div>
</body>
</html>
